This is a paper first. The coded is just part of the content.
- Write a paper about your Arduino based project.
The paper should include research about the Arduino platform (atmega328p), Architecture and Organization.
In your paper, describe your design, the choices you made and what you did to implement the various sections.- memory
- bus architecture
- RISC features
- register file
- instructions
- addressing
- Your project should demonstrate Arduino programming and some of the coding must use assembly.
- arduino programming
- assembly
- It should include communication between two Arduinos, using a protocol of your own design. (Serial over data pins)
Since it is your implementation of a protocol, it may involve timing and pin state sampling, serial to parallel (shift register) elements etc. - It should have at least one table lookup somewhere in the solution written in assembly.
- It should make use of (some) motion, LED, and/or sound as status indicators.
- It should address the communication based on a cipher for security. (Using Caesar Cipher)
- It should include user validation.
- Use some visual display elements, to add to the overall presentation.
Example user story:
- Enter a user ID code and receive a confirmation (LEDs, flag waving, sound).
- If valid return a cipher key
- Send the cipher key back (confirming the shift with the user), encrypted, and confirm the exchange. This will demonstrate the key was received and the cipher agreed to.
- Send the cipher encrypted text from the first Arduino to the second Arduino, where it will be decoded back to plain text and displayed.
If any stage fails, reset the program. There will be feedback provided when the program resets. There will also be status indicators to display the progress.
Write Arduino:
- The user enters their ID code on the 4x4 keypad, and then the user presses a button to submit it.
- Give feedback that user ID was a successful or failed attempt.
- After the user ID is validated, the user enters a message to send and presses a button to submit it.
- Encrypt the message.
- Send the encrypted message to the second Arduino, using the custom protocol outlined below.
- Receive acknowledgement from the Read Arduino and update status indicator.
- Return to beginning state.
Read Arduino:
- Poll for beginning of the custom protocol outlined below.
- Read in the user ID and encrypted message from the protocol.
- Validate that the message was received successfully, making sure to provide user feedback.
- After receiving a successful message according to the protocol, decrypt the message message and display it.
- After decrypting and displaying the message, return an acknowledgement to the write Arduino.
Individual Byte:
Each nibble of information is sent with a protocol code (the code is a nibble as well). This means each nibble of information results in one byte of informaiton.
Bits | What it is |
---|---|
7 - 4 (most significant bits) | protocol codes |
3 - 0 (least significant bits) | data |
Protocol Codes:
Code | Description |
---|---|
0xf | Interupt |
0x4 | User ID |
0x6 | Encrypted Message |
0x8 | Successful Acknowledgement (ACK) |
anything else | Invalid |
Full Protocol for sending a message:
Bytes | Description |
---|---|
0 - 3 | User ID |
4 - 7 | Encrypted Message |
Full Protocol for successful response acknowledgement:
A single byte with the value 0x80.