Commit a0e6ef45 authored by Robert Sprowson's avatar Robert Sprowson
Browse files

Use IIC status definitions from HALEntries header

Mark HAL_IICDevice as a null entry, since bit 4 of the flags says we don't support that mode of operation anyway.

Version 0.32. Tagged as 'BCM2835-0_32'
parent f38116c4
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "0.31"
Module_Version SETA 31
Module_MajorVersion SETS "0.32"
Module_Version SETA 32
Module_MinorVersion SETS ""
Module_Date SETS "19 Dec 2013"
Module_ApplicationDate SETS "19-Dec-13"
Module_Date SETS "13 Apr 2014"
Module_ApplicationDate SETS "13-Apr-14"
Module_ComponentName SETS "BCM2835"
Module_ComponentPath SETS "mixed/RiscOS/Sources/HAL/BCM2835"
Module_FullVersion SETS "0.31"
Module_HelpVersion SETS "0.31 (19 Dec 2013)"
Module_FullVersion SETS "0.32"
Module_HelpVersion SETS "0.32 (13 Apr 2014)"
END
/* (0.31)
/* (0.32)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 0.31
#define Module_MajorVersion_CMHG 0.32
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 19 Dec 2013
#define Module_Date_CMHG 13 Apr 2014
#define Module_MajorVersion "0.31"
#define Module_Version 31
#define Module_MajorVersion "0.32"
#define Module_Version 32
#define Module_MinorVersion ""
#define Module_Date "19 Dec 2013"
#define Module_Date "13 Apr 2014"
#define Module_ApplicationDate "19-Dec-13"
#define Module_ApplicationDate "13-Apr-14"
#define Module_ComponentName "BCM2835"
#define Module_ComponentPath "mixed/RiscOS/Sources/HAL/BCM2835"
#define Module_FullVersion "0.31"
#define Module_HelpVersion "0.31 (19 Dec 2013)"
#define Module_LibraryVersionInfo "0:31"
#define Module_FullVersion "0.32"
#define Module_HelpVersion "0.32 (13 Apr 2014)"
#define Module_LibraryVersionInfo "0:32"
......@@ -30,6 +30,7 @@
AREA |ARM$$code|, CODE, READONLY, PIC
GET Hdr:ListOpts
GET Hdr:HALEntries
GET hdr.BCM2835
GET hdr.StaticWS
......@@ -38,7 +39,6 @@
EXPORT IIC_Init
EXPORT HAL_IICBuses
EXPORT HAL_IICType
EXPORT HAL_IICDevice
EXPORT HAL_IICTransfer
EXPORT HAL_IICMonitorTransfer
......@@ -53,13 +53,6 @@ $label BaseAddr $r1, $r2 ; Form a pointer to the device's
IICVersion * 210 ; A guess! Rev. 2.1
; IIC divider to give 100 kHz
IICDivider * 2496
; Definitions of HAL IIC return codes
IICStatus_Completed * 0
IICStatus_InProgress * 1
IICStatus_NoACK * 2
IICStatus_Busy * 3
IICStatus_Slave * 4
IICStatus_Error * 5
; Definitions of RISC OS IIC flags in iic_transfer structure
IICFlag_Retry * 1 << 29 ; Ignored at this level
IICFlag_ChecksumOnly * 1 << 30
......@@ -120,11 +113,8 @@ HAL_IICBuses
MOV pc, lr
HAL_IICType
MOV a1, #(IICVersion << 20); IIC version
ORR a1, a1, #2 ; Add in the HAL flags
MOV pc,lr
HAL_IICDevice
MOV a1, #(IICVersion << IICFlag_ProtocolVersionShift) ; IIC version
ORR a1, a1, #IICFlag_HighLevel ; Add in the HAL flags
MOV pc,lr
; Get the total length of transfers linked with nostart set
......@@ -390,5 +380,5 @@ HAL_IICMonitorTransfer
MOVNE a1, #IICStatus_Busy
MOV pc,lr
END
END
......@@ -76,7 +76,6 @@
IMPORT IIC_Init
IMPORT HAL_IICBuses
IMPORT HAL_IICType
IMPORT HAL_IICDevice
IMPORT HAL_IICTransfer
IMPORT HAL_IICMonitorTransfer
......@@ -416,7 +415,7 @@ HAL_EntryTable DATA
HALEntry HAL_IICType
NullEntry ; HAL_IICSetLines
NullEntry ; HAL_IICReadLines
HALEntry HAL_IICDevice
NullEntry ; HAL_IICDevice
HALEntry HAL_IICTransfer
HALEntry HAL_IICMonitorTransfer
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment