Question: Develop a program in C and upload it into your Arduino Mega 2560 board to implement a simple credit card management system. The Arduino Mega

Develop a program in C and upload it into your Arduino Mega 2560 board to implement a simple credit card management system. The Arduino Mega 2560 should interact with the user via the Serial Monitor. This Question is based on AVR programming in C. The program should do as described below. (Use the C code I have already developed below, making any changes if neccessary) .

The use of high level ArduinoFunctions (seehttp://arduino.cc/en/Reference/HomePage, under Functions) is not permitted.Significant marks will be deducted if any of the functions is used. Native C functionsare however permitted.

Thank you for your help! :)

Implemented c source code:-

==================== #include #include "structure.h" #include int main() { struct Bank_Account array[10]; int size, option, account_no, amount; int retval,position; printf(" ---------------------------------- "); printf(" **** Welcome to the Bank of Melbourne***** "); printf(" Please Read Number of customer records you want to enter:"); scanf("%d", &size); Read_Data(array, size); while(1) { printf(" ---------------------------------- "); printf(" ****** MENU ******** "); printf(" 1.To display all customer Records"); printf(" 2.To deposit amount"); printf(" 3.To withdraw amount"); printf(" 4.To search a record"); printf(" 5.Exit:"); printf(" Select Any Option "); scanf("%d", &option); switch (option) { case 1: Display_Record(array, size); break; case 2: printf(" Please Enter your account number:"); scanf("%d", &account_no); printf(" Please Enter amount to deposit:"); scanf("%d", &amount); Deposit(array, size, account_no, amount); break; case 3: printf(" Please Enter your account number:"); scanf("%d", &account_no); printf(" Please Enter amount to withdraw:"); scanf("%d", &amount); withdrawal(array, size, account_no, amount); break; case 4: printf(" Please Enter account number to search"); scanf("%d", &account_no); retval = Search_Account(array, size, account_no); position=retval; if (retval == - 1) { printf(" No Record Found"); } else { printf(" A/c Number:\tName:\tBalance:\tInterestRate "); printf("%d\t%s\t%d ",array[position].account_no, array[position].name,array[position].balance,array[position].interestRate); } break; case 5: exit(0); } } return 0; } void Read_Data(struct Bank_Account list[10], int size) { int i; for(i=0;i

WHAT THE C CODE ABOVE WAS BASED ON + more instructions on the Ardiuno requirements:

 Develop a program in C and upload it into your ArduinoMega 2560 board to implement a simple credit card management system. The

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!