[Breadboard/PIC18F4550/PID]

Discrete Transfer Function and PID example.

1- Use potentiometer to define setpoint
2- Use RB0 switch to select open loop or closed loop with PID controller

Use octave or matlab to calculate transfer function coeficients:

>>gs = tf([1],[0.2 0.25 1]);

Transfer function 'gs' from input 'u1' to output ...

               1
 y1:  --------------------
      0.2 s^2 + 0.25 s + 1

Continuous-time model.

>> gd=c2d(gs,0.1)

Transfer function 'gd' from input 'u1' to output ...

       0.02389 z + 0.02291
 y1:  ----------------------
      z^2 - 1.836 z + 0.8825

Discrete-time model Ts=0.1.


MPLABX PID project


Download (pzw)

View Online


[Breadboard/PIC18F4550/test_b0]

Simple example for testing board features.

1- Ask to turn on all dip switches;
2- Tests LCD display;
3- Tests 7-segment displays;
4- Test the red LEDs connected to the PORTB and PORTD;
5- Tests push buttons;
6- Test the serial port transmitting;
7- Test the serial port receiving;
8- Tests AD converters connected to potentiometers;
9- Test Relays
10- Tests temperature measurement;
11- Turn on the Heater;
12- Turn on the fan and measure the speed.
13- Tests the matrix keyboard
14- Tests internal eeprom

MPLABX test_b0 project


Download (pzw)

View Online


[McLab2/PIC18F4550/test_b3]

Simple example for testing board features.

1- Tests LCD display;
2- Tests 7-segment displays;
2- Test the red LEDs;
3- Tests push buttons;
4- Tests internal eeprom;
5- Tests external eeprom 24C04;
6- Test serial sending and receiving data;
7- Tests AD converter connected to the potentiometer;
8- Tests temperature measurement;
9- Turn on the Heater;
10- Turn on the fan and measure the speed.

MPLABX test_b3 project

Others compilers test_b3 project

Download (pzw)

View Online


[PICGenios/PIC18F4550/espmsim_server]

Serial esp8266/espmsim TCP server

Open the esp8266 modem simulator in tools menu and connect the serial 
(or a real esp8266 connected in a real serial port).

To use the serial port, first configure the com0com or tty0tty as 
described in the help.

When the server is loaded, open a browser in the address http://127.0.0.1:2000 

MPLABX esp_server project

Download (pzw)

[PICGenios/PIC18F4550/Parts_Demo]

Simple example for servomotor and stepper motor testing.

Servo motor connected in RB0 controlled by AN0 analog channel.
Stepper motor connected to RB7, RB6, RB5 and RB4.
MPLABX Parts_Demo project

Download (pzw)

View Online


[PICGenios/PIC18F4550/Serial_lcd]

Serial/LCD simple test.

Open the serial term and type lines with LF terminator.

MPLABX Serial_lcd project

Download (pzw)

View Online


[PICGenios/PIC18F4550/srtank_test]

Serial remote tank simple test

Open the Serial remote tank in tools menu and connect the serial.

To use the serial port, first configure the com0com or tty0tty as 
described in the help.
MPLABX srtank_test project

Download (pzw)

[PICGenios/PIC18F4550/test_b4]

Simple example for testing board features.

1- Ask to turn on all dip switches;
2- Tests LCD display;
3- Tests 7-segment displays;
4- Test the red LEDs connected to the PORTB and PORTD;
5- Tests push buttons;
6- Test the serial port transmitting;
7- Test the serial port receiving;
8- Tests AD converters connected to potentiometers;
9- Test Relays
10- Tests temperature measurement;
11- Turn on the Heater;
12- Turn on the fan and measure the speed.
13- Tests the matrix keyboard
14- Tests internal eeprom

MPLABX test_b4 project

Others compilers test_b4 project

Download (pzw)

View Online


[X/PIC18F4550/Test_x]

Simple board X example

Simple example to use ADC ,switches and button inputs to control LEDs on outputs.
Based on board of tutorial Creating New Boards.

MPLABX board_x.X project


Download (pzw)

View Online