Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
ctboard:peripherals:7segment_raw [2016/06/08 11:08] – [7 Segment Raw Interface] feurctboard:peripherals:7segment_raw [2026/06/25 15:02] (current) – [Programming Example] scbj
Line 1: Line 1:
-====== 7 Segment Raw Interface ======+====== 7-Segment Display - Segment Control Mode ======
  
-This is the "raw" interface. Each segment of the display can be controled independently. The segments are **"active-low"**, e.g. the segment is on if a logical "0" is written to it. \\ \\+Each segment of the display can be controlled independently. The segments are **"active-low"**, e.g. the segment is on if a logic "0" is written to it. \\ \\
  
 > {{ctboard:ctboard_mode_1.svg?48px }} {{ctboard:ctboard_mode_2.svg?48px }} {{ctboard:ctboard_mode_3.svg?48px }} {{ctboard:ctboard_mode_4.svg?48px }} Please make sure the CT Board is in the correct mode. > {{ctboard:ctboard_mode_1.svg?48px }} {{ctboard:ctboard_mode_2.svg?48px }} {{ctboard:ctboard_mode_3.svg?48px }} {{ctboard:ctboard_mode_4.svg?48px }} Please make sure the CT Board is in the correct mode.
 > Supported [[ctboard:mode_switch|modes]]: **1**, **2**, **3**, **4**  > Supported [[ctboard:mode_switch|modes]]: **1**, **2**, **3**, **4** 
 \\ \\
 +
 +===== Registers =====
 +
 +The registers are read / write.
 +
 +\\ {{ctboard_7seg_raw_reg.svg}} \\ \\
 +
 +===== Diagram =====
 +
 +\\ {{ctboard_7seg_raw.svg?700em}} \\ \\
  
 ===== Programming Example ===== ===== Programming Example =====
  
-The code snippet bellow shows how to use the 7 segment display in segment control mode.+The code snippet below shows how to use the 7-segment display in segment control mode.
  
 <code c> <code c>
Line 20: Line 30:
 \\ \\
  
-<code asm+<code text
-ADDR_SEG7_RAW   EQU      0x60000110+.equ ADDR_SEG7_RAW,  0x60000110
  
-                LDR      r0, =ADDR_SEG7_RAW +        ldr     r0,  =ADDR_SEG7_RAW 
-                STRB     r1, [r0, #0]                     ; Write byte of segment data to DS0. +        strb    r1,  [r0, #0]          // Write byte of segment data to DS0. 
-                STRH     r1, [r0, #2]                     ; Write half word of segment data to DS3..2. +        strh    r1,  [r0, #2]          // Write half word of segment data to DS3..2. 
-                STR      r1, [r0, #0]                     ; Write word of segment data to all displays.+        str     r1,  [r0, #0]          // Write word of segment data to all displays.
 </code> </code>
 \\ \\
  
-===== Registers ===== 
- 
-The Registers are read / write. 
- 
-\\ {{ctboard_7seg_raw_reg.svg}} \\ \\ 
- 
-===== Diagram ===== 
- 
-\\ {{ctboard_7seg_raw.svg?700em}} \\ \\ 
  • ctboard/peripherals/7segment_raw.1465384115.txt.gz
  • Last modified: 2016/06/08 11:08
  • by feur