sblib
Folders and files
Name | Name | Last commit date | ||
---|---|---|---|---|
parent directory.. | ||||
last review: com_objects.cpp: - added sending buffer free check before new data is loaded - fixed possible loop when app was writing an object and lib was searching to update local object in same group bus.cpp: - limit rate of sending telegram to 28 per second to avoid thermal breakdown of sending circuit review on bus.cpp: - added some comments - fixed collision detection issue while sending ACK/NACK/BUSY - introduction of collision detection window according to spec for pulse duration of 25us - 70us due to propagation delay - added some states to SM for better readability of the code, Busy handling,... - added error handling, convey info to upper layers - added local rx buffer for parallel processing of rx telegram and bus-receiving and reply with busy to remote sender - added busy acknowledgment handling - added some debug macros, use of timer32_0 for debugging of state machine timing serial I/F - debugging with high speed serial terminal interface (1.5Mbaud) at PIO2_7 and PIO2_8 old review to fixe some issues in bus.cpp: - collision detection, introduction of windows to avoid detection of refelctions of low bit pulse which can extend the bit duration up to 70us - handling of default phy addr. (e.g. in case of uninitialized SW), set to default 15.15.255 for normal device or allow 0.0.0 for router -compiled with ROUTER definition - setting correct waiting time for reply and prio telegrams (according to bits in control byte of telegram) in com_objects.cpp: - handling of read/write of object by the APP, check for correct flag before send telegram to bus or local object (in case they share same group addr.) (not completed yet) - added default telegram rate limit in order to avoid sending stage overload Selfbus EIB Library =================== The library uses the following ARM components: Bus access: - Pin P1.8 for EIB IN - Pin P1.9 for EIB OUT - Pin P2.0 for programming mode led and button - 16bit Timer #1 Test setup ---------- For the ARM you can use a LPCxpresso prototyping board. The LPC1115 is ideal, but LPC1114 also works. For bus access you can use a Selfbus LPC controller board. Any controller board should be sufficient, even a module like the Gira smoke detector. Remove the LPC922 from the controller board and make connections from the following pins of the LPC922 socket to the ARM prototyping board: LPC pin 2 to ARM pin P2.0 LPC pin 3 to ARM pin P1.9 LPC pin 5 to ARM pin GND LPC pin 8 to ARM pin P1.8 Add a 100pF condensator between ARM pin 1.8 and GND BCU type -------- Application and library must have the same BCU type. The BCU type is set by the compile time constant BCU_TYPE. It has to bei either 10 (for BCU 1) or 20 (for BCU 2). If in doubt, use BCU 1. To configure it, navigate in Eclipse into the project properties, C/C++ Build > Settings > Tool Settings (tab) > MCU C++ Compiler > Preprocessor In the top box "Defined symbols (-D)" there shall be a line BCU_TYPE=10 (or =20) its there for the library and the same line shall be in the application project