Skip to content

Commit 19c46c5

Browse files
committed
Attempt to correct markup of README.md
1 parent f57b6d2 commit 19c46c5

1 file changed

Lines changed: 55 additions & 48 deletions

File tree

README.md

Lines changed: 55 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,74 @@
11
_This manual is released by the author into the public domain._
22

33
#T24C02A EEPROM set-up:
4-
Connect Arduino GND to EEPROM GND.
5-
Connect Arduino SDA to EEPROM SDA.
6-
Connect Arduino SCL to EEPROM SCL.
7-
Connect Arduino 5V to EEPROM Vcc.
4+
- Connect Arduino GND to EEPROM GND.
5+
- Connect Arduino SDA to EEPROM SDA.
6+
- Connect Arduino SCL to EEPROM SCL.
7+
- Connect Arduino 5V to EEPROM Vcc.
88

99
#Arduino set-up:
10-
Open the Arduino IDE.
11-
Connect Arduino (I used USB).
12-
Choose correct board and serial port in Arduino IDE.
13-
Upload code to Arduino using the IDE.
14-
Open serial console (Ctrl+Shift+M).
15-
The board waits 4 seconds after Arduino reset (end of upload).
16-
Then it promps for I²C address.
17-
If you miss this prompt, just enter the address, or if you don't know the address, enter the character 'P'.
10+
- Open the Arduino IDE.
11+
- Connect Arduino (I used USB).
12+
- Choose correct board and serial port in Arduino IDE.
13+
- Upload code to Arduino using the IDE.
14+
- Open serial console (Ctrl+Shift+M).
15+
- The board waits 4 seconds after Arduino reset (end of upload).
16+
- Then it promps for I²C address.
17+
- If you miss this prompt, just enter the address.
18+
- If you don't know the address, enter the character 'P'.
1819

1920
#Getting started:
2021
If you opened the serial console soon enough, you'll be prompted for an I²C address or a 'P'.
22+
2123
If you did not open the serial console within four seconds after the Arduino reset, you will not see the prompt, but the Arduino will still patiently wait for your input.
24+
2225
Enter the address, or the character 'P'.
26+
2327
##The address:
24-
The Arduino wire library works with 7-bit adresses.
25-
The Arduino Serial library can easily parse decimal values, not hex codes.
26-
Therefore the default T24C02A address 0xA0 is rendered thus:
27-
Shift right one bit to get 7-bit address: 0xA0 >> 1 → 0x50
28-
Convert to decimal: 0x50 → 5×16 + 0 = 80
28+
__The Arduino wire library works with 7-bit adresses.__
29+
30+
The Arduino Serial library can easily parse decimal values, not hex codes.
31+
32+
Therefore the default T24C02A address 0xA0 is rendered thus:
33+
34+
Shift right one bit to get 7-bit address: 0xA0 >> 1 → 0x50
35+
36+
Convert to decimal: 0x50 → 5×16 + 0 = 80
2937
##Polling:
30-
If you entered the character 'P', the Arduino will poll all 128 possible addresses on the I²C bus.
31-
It wil show you the address + answer of the devices that answered.
32-
If you have successfully entered the address, you will be in the main shell menu.
38+
If you entered the character 'P', the Arduino will poll all 128 possible addresses on the I²C bus.
39+
It wil show you the address + answer of the devices that answered.
3340

3441
#The main menu:
42+
Once you have successfully entered an address, you will arrive in the main shell menu.
43+
3544
You will be asked for a command char:
36-
R — Read
37-
W — Write
38-
S — Set I²C address
39-
useful if you set it wrong, have multiple EEPROMs or have a T24C04A, T24C08A or T24C16A IC.
40-
P — Re-poll the I²C bus.
45+
R — Read
46+
W — Write
47+
S — Set I²C address _useful if you set it wrong, have multiple EEPROMs or have a T24C04A, T24C08A or T24C16A IC._
48+
P — Poll the I²C bus.
4149
##Reading:
42-
Follow the instruction:
43-
Enter the start address for the read.
44-
Enter the number of bytes to be read.
45-
The device will print all characters on a single line.
46-
Followed by a line of statistics.
47-
Optionally followed by a line indicating an error.
50+
- Follow the instruction:
51+
- Enter the start address for the read.
52+
- Enter the number of bytes to be read.
53+
- The device will print all characters on a single line.
54+
- Followed by a line of statistics.
55+
- Optionally followed by a line indicating an error.
4856
##Writing:
49-
Follow the instruction:
50-
Enter the start address for the write.
51-
Enter the string to be written.
52-
Escape numerical ASCII representations of characters by prefixing them with an '@'.
53-
@64 is the @ character itself.
54-
The device will print each character submitted to the device.
55-
The device will print a human readable error message for each unsuccessful write.
56-
The device will retransmit (including reprint of) the character up to NUM_TRIES times.
57-
NUM_TRIES is set to 10 by default in the code.
58-
After ten failed tries the device:
59-
Will print an error message indication.
60-
It will skip this address.
61-
It will continue to write the next character to the next location in the EEPROM.
57+
- Follow the instruction:
58+
- Enter the start address for the write.
59+
- Enter the string to be written.
60+
_Escape numerical ASCII representations of characters by prefixing them with an '@'._
61+
_@64 is the @ character itself, in case you want to write an actual @._
62+
- The device will print each character submitted to the device.
63+
- The device will print a human readable error message for each unsuccessful write.
64+
- The device will retransmit (including reprint of) the character up to NUM_TRIES times.
65+
_<NUM_TRIES> is set to 10 by default in the code._
66+
__After ten failed tries the device:__
67+
- Will print an error message indication.
68+
- It will skip this address.
69+
- It will continue to write the next character to the next location in the EEPROM.
6270
##Setting the I²C address:
63-
The same procedure as detailed in the section "Getting Started", see above.
71+
The same procedure as detailed in the section "Getting Started", see above.
6472
##Polling:
65-
The same procedure as detailed in the section "Getting Started", see above.
66-
This polling is not done as part of a change of address.
67-
The device will give information on the polled devices, and return to the menu.
73+
The same procedure as detailed in the section "Getting Started", see above.
74+
This polling is not done as part of a change of address. Therefore, the device will give information on the polled devices, and return to the menu immediately afterwards.

0 commit comments

Comments
 (0)