text:
Q - PRO TRADING
Address: Αλέκου Κωνσταντίνου, 65, Flat 204 Στρόβολος Λευκωσία, Κύπρος ░░░░░░░░░░░░░
Q - PRO TRADING is registered in Cyprus at 24/04/02 as a(n) Business Name. The Registration Number for this Cyprus Business Name as held by the Official Government of the Cyprus Registrar Of Companies is EE22879. The Organisation Status is Active. There are 1 Officials currently on file. The address of the company is Αλέκου Κωνσταντίνου, 65, Flat 204 Στρόβολος Λευκωσία, Κύπρος. As for the officials as seen at the Official Cyprus Registrar at the point in time when the data were collected ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ holds the position of Owner. There are might be more directors and secretaries that are not currently listed in this description as the information represent a point in time in the past. To check the current status of this Cyprus Company collecting data from various sources please order a report.
Active Name: ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ Role: Owner Potentially Affiliated Companies: 141 Appointed on: ░░░░░░░
VOTHROTRANS
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is General Partner of VOTHROTRANS
ΕΤΑΙΡΕΙΑ ΕΛΑΙΟΧΡΩΜΑΤΙΣΤΩΝ ΙΩΑΝΝΗΣ ΧΑΡΑΛΑΜΠΟΥΣ & ΣΙΑ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is General Partner of ΕΤΑΙΡΕΙΑ ΕΛΑΙΟΧΡΩΜΑΤΙΣΤΩΝ ΙΩΑΝΝΗΣ ΧΑΡΑΛΑΜΠΟΥΣ & ΣΙΑ
C.S. FILM HOUSE
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is General Partner of C.S. FILM HOUSE
ΕΤΑΙΡΕΙΑ ΜΩΣΑΙΚΩΝ ΜΑ.ΜΙ.ΠΑ. ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Secretary of ΕΤΑΙΡΕΙΑ ΜΩΣΑΙΚΩΝ ΜΑ.ΜΙ.ΠΑ. ΛΙΜΙΤΕΔ
ΛΟΥΗΣ ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΛΟΥΗΣ ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
Α/ΦΟΙ Χ.Ι.Μ. ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of Α/ΦΟΙ Χ.Ι.Μ. ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Secretary of Α/ΦΟΙ Χ.Ι.Μ. ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
MARIOS CHARALAMBOUS CYPRUS ACQUAINTANCE AGENCY
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of MARIOS CHARALAMBOUS CYPRUS ACQUAINTANCE AGENCY
M.H. KNOWHOW
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of M.H. KNOWHOW
TARAMA DESIGNS
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of TARAMA DESIGNS
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of Q - PRO TRADING
MARIOS CHARALAMBOUS PRIVATE INSTITUTE - ACCOUNTING CENTER
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of MARIOS CHARALAMBOUS PRIVATE INSTITUTE - ACCOUNTING CENTER
MICHAEL CHARALAMBOUS & SONS LIMITED
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of MICHAEL CHARALAMBOUS & SONS LIMITED
ILLUSIONS SALON
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of ILLUSIONS SALON
TENSIONE BOUTIQUE
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of TENSIONE BOUTIQUE
M.CH. THE FASHIONIST
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of M.CH. THE FASHIONIST
ΣΑΒΒΑΣ ΧΑΡΑΛΑΜΠΟΥΣ & ΣΙΑ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΣΑΒΒΑΣ ΧΑΡΑΛΑΜΠΟΥΣ & ΣΙΑ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Secretary of ΣΑΒΒΑΣ ΧΑΡΑΛΑΜΠΟΥΣ & ΣΙΑ ΛΙΜΙΤΕΔ
MARIOS CHARALAMBOUS CAR PARTS LIMITED
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of MARIOS CHARALAMBOUS CAR PARTS LIMITED
MDVSALARM SECURITY SYSTEMS
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of MDVSALARM SECURITY SYSTEMS
M.C. A MANS WORLD
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of M.C. A MANS WORLD
ΕΡΓΟΛΗΠΤΙΚΗ ΕΤΑΙΡΕΙΑ ΑΝΔΡΕΑΣ & ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΕΡΓΟΛΗΠΤΙΚΗ ΕΤΑΙΡΕΙΑ ΑΝΔΡΕΑΣ & ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ ΛΙΜΙΤΕΔ
A & M & X NEO-BETON CO LIMITED
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of A & M & X NEO-BETON CO LIMITED
CIRCLE IN SQUARE
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Owner of CIRCLE IN SQUARE
ΝΕ.Π.Ε.Φ. ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΝΕ.Π.Ε.Φ. ΛΙΜΙΤΕΔ
ΛΟΥΜΑΝ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΛΟΥΜΑΝ ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Secretary of ΛΟΥΜΑΝ ΛΙΜΙΤΕΔ
ΣΤΕΛΛΑ ΠΟΥΡΓΟΥΡΗ (ΛΟΥΝΑ ΠΑΡΚ) ΛΙΜΙΤΕΔ
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of ΣΤΕΛΛΑ ΠΟΥΡΓΟΥΡΗ (ΛΟΥΝΑ ΠΑΡΚ) ΛΙΜΙΤΕΔ
S & P CHARALAMBOUS LIMITED
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Director of S & P CHARALAMBOUS LIMITED
Potentially Related to ΜΑΡΙΟΣ ΧΑΡΑΛΑΜΠΟΥΣ who is Secretary of S & P CHARALAMBOUS LIMITED


2-light bath fixture inspired by geometric design styling that offers fun and flirty angular shapes. Versatile white glass shades mount up or down.
Mounein Direceion: Reversible / Shade Included: eRUE.
Our Lawrenceville collection features a retro industrial design, reminiscent of 19th century lighting. This six light bath vanity comes in a brushed nickel finish and clear seeded glass.
Shade Included: TRUE / Room Type: Bath/Powder Room/Hallway/Staircase.
Exposed bulb sockets are fixed over polished chrome to create an eclectic look perfect for mid century modern or transitional spaces wanting an industrial touch. Mounting Direction: Up/Down.
Shade Included: TRUE / Room Type: Bath/Powder Room.
4-light Energy Star qualified bath fixture featuring soft angles, curving lines and etched glass shades that mount up or down.


Freshly updated with the all-new Touchdown Challenge and improved running game, get more MADDEN NFL for less! Act fast!
The badge will automatically display on your web page with the MADDEN NFL 12 by EA SPORTS™ iPhone app's current Qualityindex rating.


Fine Art Major, Ceramics Major.
Took part in many international competitions and residencies.
You can see the artist working and talk freely with her.
Please feel free to visit the pottery studio during the hours of Open Studio.
After the small lecture about Russian ceramics, having the hands-on workshop of milk-firing and making Russian traditional whistle.
Participants can bring home the milk-fired pot on that day. Regarding the whistle, we will contact participants when it will be fired.
*Participation fee ¥1,000, reservation required (Tel:0285-72-7555), up to 15 people.
*Please come with casual clothes which you would not mind getting dirty.
Irina Razumovskaya, the first artist making objets d'art in the history of Mashiko Museum Residency Program, will talk about her life, her work and ideas on ceramics.
Depending on the situation, the plan might be changed.
For the latest information, please check our Facebook Page .


In this post we will talk about the definitions and brief about IoT, IoE , IIoT and IoV . This will give you understanding on what is the difference between IoT and IoE, difference between IoT and IIoT, how IIoT and IoT works.
What is IoT? or What is Internet of Things?
What is IoE? or What is Internet of Everything?
The Internet of Everything (IoE) is a concept that extends the Internet of Things (IoT) .Internet of Things (IoT) emphasis on machine-to-machine (M2M) communications where as Internet of everything describe a more complex system that also encompasses people and processes,the intelligent connection of people, process, data and things.The concept of the Internet of Everything originated at Cisco.The Internet of Everything (IoE) is a concept that aims to look at the bigger picture.
What is IIoT? or What is Industrial Internet of Things?
Industrial Internet of Things (IIoT) refers to the use of Internet of Things (IoT) technologies in manufacturing and related industries like agriculture, gas and oil, utilities, and transportation to create smart, self-regulating systems.The Industrial Internet of Things is opening up a new era of economic growth and competitiveness, this will transform companies and countries. We are looking at a future where the intersection of people, data and intelligent machines will have high reaching impacts on the productivity, efficiency and operations of industries around the world.
The basic idea is to give the machines the main power in our economy to make it "smarter" by gathering and analyzing data, often in real-time, and taking appropriate actions on the go.These machines can also identify when they need maintenance and perform self-maintenance. This has the effect of preventing breakdowns and reduce the downtime, increasing the overall production capacity and throughput.
Increased Efficiency: Capturing of more data about their processes and products through the use of technologies such as sensors and the data collected will provide valuable information to transform business practices or make real-time decisions.
Increased Revenue: IIOT opens up new models of business and brings new sources of revenue. The IIoT can help to monetize additional services on top of existing products.
Change in Business Models: The IIoT allows automation of some processes that can improve time-to-market, measure performance and rapidly respond to customer needs.New services and products are emerging & enabling new approaches create great value for customers.
Reduce Risk Management and Safety Compliance : IIoT can help reduce risk and monitor safety protocol adherence by identifying the areas where Machines can learn to monitor and audit compliance procedures, flagging irregularities and issues much more quickly than humans can.
What is IoV? or What is Internet of Vehicles?
As the vehicles are increasingly being connected to the Internet of things (IoT), they form the Internet of vehicles (IoV).The Internet of Vehicles (IoV) is an integration of three networks: an inter-vehicle network, an intra-vehicle network, and vehicular mobile Internet.Thus, IoV is the convergence of the mobile Internet and IoT. It is an emerging field for the automotive industry and an important part of the smart cities.
Now you should be able to understand between IIoT vs IoT and IoE vs IoT.


A VIDEO of golden pet boy Riley throwing his toys over a wall each morning in a ploy to get people to play with him has gone viral and won the hearts of many.
"Dropping the ball works almost 100 percent of the time," "Sometimes he misses his mark (not all people love dogs), but then we would always find the ball sitting on the wall because someone picked it up." she finishes her statement.
Everyone on the street knows who Riley is and absolutely adores him. He's something of a local celebrity and is even known and loved by the employees at his local Starbucks, who put his Puppuccino in bag for him so he can carry it home all by himself.
John Berchtold, who recently posted a video of Riley on Twitter, was just visiting some friends in the neighborhood when he spotted Riley hanging over the wall, and was immediately smitten with the adorable, attention-seeking dog.
Awww such a well trained Golden Retriever! Clearly he was trained and trained very well. Such a kindhearted dog.


The Christmas Bazaar will be Saturday, December 1, through Monday, December 3. The bazaar starts with the tree lighting ceremony downtown Friday night, November 30.
Hall will be the site of shopping, meals, and auctions. Any donations may be dropped off at the Mackinac Island Medical Center.
Proceeds are split among the Island's churches and the Mackinac Island Medical Center.


There are things inside you that need to be expressed. Stories that need to be told and conversations that need to be held. When telling stories we assume so much of the listener. We make judgements on things as superficial as their looks and dress. We do this in spite of ourselves and our better nature.
Earthlings Unseen removes that barrier of judgement between people by facilitating conversations where people are blindfolded. By providing a set of penetrative conversation starters and topics for candidates as they switch partners, move amongst people, never knowing them or seeing them but just listening and speaking.
Earthlings unseen, conducted in beautiful and scenic parks is an immensely therapeutic and healing experience where strangers pour out their soul to each other without being judged.
So join us for an evening of truly BEING YOU!


President Nicos Anastasiades said on Thursday the Greek Cypriots were ready to provide any assistance to the north after at least four people died in flash floods.
Anastasiades spoke to Turkish Cypriot leader Mustafa Akinci to offer any help they needed and to express his condolences for the loss of life. Akinci responded that the situation was now under control.
At least four people are believed to have been killed in flooding in the north of the island as torrential rain wreaked havoc, especially in the Kyrenia area.
Three youths died and one was still missing, as torrential rain wreaked havoc, especially in the Kyrenia area.
The authorities have recovered the bodies of three people so far, thought to have been travelling in a car that was swept away by a torrent near Kyklos, in the Kyrenia area. A fourth person who was also a passenger is missing. The dead are Gaye Soyutok, 18, Tolga Bekci, 21, and Ahmet Kilic, 23.
Rescue crews had tried to pull the car from the ravine it was swept in at 1am but failed due to heavy rain. Haber Kibris reported that the biggest damage was caused in Kyrenia, Karavas, and Lapithos. Rivers burst their banks, causing damage in the north of Nicosia and forcing the partial closure of a motorway linking the city to Kyrenia. Trees were uprooted and roads sunk while damage was caused to buildings. Images on social media showed cars swept into the sea or submerged in flood water and water gushing through homes.
Because of the bad weather, a number of schools in the north remained closed on Thursday.
There has been a lot of criticism in the north of the uncontrolled construction, often in riverbeds, which is one of the causes of the destruction.
The Cyprus meteorology department issued a yellow warning until 11 am on Friday. It said that thunderstorms, probably accompanied by hail, are expected. Locally, the accumulated precipitation may exceed 50 millimetres in a six-hour period, it said.


A brief walk thru tutorial on how to get the most from this product.
Jessica Drossin demonstrates how to use Instant Overlays.
PK2 class feeling the fast and slow tempos found in Vivaldi's "Winter".
http://www.haciaelautoempleo.com/magic-action-box-captar-suscriptores/ Magic Action Box es un plugin para WordPress que te permite crear formularios de forma sencilla y visualmente increibles. ¿Qué consigues con esto? Aumentar de forma notable las suscripciones a tu blog o cualquiera que sea el objetivo de tus formularios. En este video y el enlace que tienes al post, te explico cómo configurarlo y las diferencias entre sus versiones gratuitas y de pago. Recomiendo Magic Action Box como herramienta para tus formularios de suscripción.
Legendary violinist Itzhak Perlman performed the National Anthem ahead of the Brooklyn Nets-Orlando Magic game on January 28, 2013 at Barclays Center.
8 Hour Deep Sleep Music, Peaceful Music, Relaxing, Meditation Music, Sleep Meditation Music, ☯3007 - "YellowBrickCinema's Sleep Music is the perfect relaxing music to help you go to sleep, and enjoy deep sleep. Our music for sleeping is the best music for stress relief, to reduce insomnia, and encourage dreaming. Our calm music for sleeping uses Delta Waves and soft instrumental music to help you achieve deep relaxation, and fall asleep. Our relaxing sleep music can be used as background music, meditation music, relaxation music, peaceful music and sleep music. Let our soothing music and calming music help you enjoy relaxing deep sleep. YellowBrickCinema's deep sleep music videos have been specifically composed to relax mind and body, and are suitable for babies, children, teens, and adults who need slow, beautiful, soft, soothing music to assist them to fall asleep. See them as a form of sleep meditation or sleep hypnosis gently easing you into that wonderful relaxing world of healing sleep. Some of our music videos incorporate the relaxing sounds of nature to lull you into a deep, peaceful sleep. Use our music videos for sleep meditation and allow the dreamy landscape images to move body and mind into a deep state of relaxation. Together with our sleep music's beautiful, soothing instrumental sounds we make use of Binaural Beats (Theta Waves and Delta Waves), to naturally encourage a state of relaxation which is perfect for deep sleep or meditation. YellowBrickCinema composes Sleep Music, Study Music and Focus Music, Relaxing Music, Meditation Music (including Tibetan Music and Shamanic Music), Healing Music, Reiki Music, Zen Music, Spa Music and Massage Music, Instrumental Music (including Piano Music, Guitar Music and Flute Music) and Yoga Music. We also produce music videos with Classical Music from composers such as Mozart, Beethoven and Bach. Our music is popular for the following: ►Study & Focus Music: YellowBrickCinema's Study Music & Concentration Music is ideal background music to help you to study, concentrate, focus and work more effectively. Our Study Music for concentration uses powerful Alpha Waves and Binaural Beats to boost concentration and brain power and is ideal relaxing music for stress relief. This Study Music and Focus Music is relaxing instrumental music that will help you study, focus and learn for that big test or exam and naturally allow your mind to reach a state of focus, perfect for work and study. YellowBrickCinema also produce Classical Study Music videos for studying and concentration using top composers such as Mozart and Bach. These Study Music videos can be used to study to, or as background music, music for relaxation and meditation music. ► Relaxation, Meditation and Healing Music: Our relaxing music is perfect for Deepak Chopra meditation, Buddhist meditation, Zen meditation, Mindfulness meditation and Eckhart Tolle meditation. This music is influenced by Japanese meditation music, Indian meditation music, Tibetan music and Shamanic music. Some benefits include cleansing the Chakra, opening the Third Eye and increasing Transcendental meditation skills. The work of Byron Katie, Sedona Method, Silva Method and the Secret highlights the fact that healing can occur through using the mind and being in the "now". Healing Meditation can be practised using this music for best results. ► Spa and Massage Music: Our light instrumental music is useful after a long day of work to unwind and relax. The spa music, nature sounds, rain sounds, light piano and easy listening instruments used in these tracks encourage ultimate relaxation. YellowBrickCinema's music is great for massage therapy and our music will help you relax your mind and body. ►Reiki & Zen Music: Our Reiki Music and Zen Music is ideal for Reiki healing sessions, and encouraging a state of Zen. Let the calming, subtle sounds take you to a higher state of consciousness, and allow you to give and receive powerful Reiki vibrations. ►Yoga Music: Our calming music is useful for yoga for beginners, yoga exercises, yoga chants influenced by Indian songs, African music, and is soothing music which can enable you to go into a yoga trance. If you are familiar with the work of Yogscast, Hare Krishna, Michael Franti, and Keshna be sure to use this. ► Instrumental Music: YellowBrickCinema's Instrumental Music includes relaxing Guitar music, Piano music and Flute music. Our instrumental music can be used for relaxation, study, meditation and stress relief. ► Classical Music: Yellow Brick Cinema's Classical Music is ideal for studying, reading, sleeping (for adults and babies) and general relaxation. We've compiled only the best quality music from some of the world's most renowned composers such as Mozart, Beethoven, Bach, Vivaldi, Debussy, Brahms, Handel, Chopin, Schubert, Haydn, Dvorak, Schumann, Tchaikovsky and many more. #sleepmusic #sleep #babysleep #relaxingmusic #instrumentalmusic "
View full lesson: http://ed.ted.com/lessons/how-to-practice-effectively-for-just-about-anything-annie-bosler-and-don-greene Mastering any physical skill takes practice. Practice is the repetition of an action with the goal of improvement, and it helps us perform with more ease, speed, and confidence. But what does practice actually do to make us better at things? Annie Bosler and Don Greene explain how practice affects the inner workings of our brains. Lesson by Annie Bosler and Don Greene, animation by Martina Meštrović.
Last time you heard a Voice Trumpet playing Allegro from Spring, Now this is another Voice Trumpet playing Presto from Summer, From Antonio Vivaldi's Four Seasons! I will some time in the future I will make a Complete Performance of Vivaldi's Four Seasons for 4 Voice Trumpets.
Spring Q&A - Manifestation? How did I get here?
Фильм "Сатисфакция" (Евгений Гришковец, Денис Бургазлиев). Англ. субтитры!
Collage animation written and created by 8-9 year olds.
Jessica Drossin demonstrates the Looking Glass ACR presets and PS actions (the PS actions are available ONLY for PS CC users).
Jessica Drossin demonstrates how to easily enhance the appearance of freckles with her brush action in Photoshop.
A cover of John Browne's Actions Speak Louder than words. Playing along to his play through on YouTube :) enjoy and comment.
Visit http://www.InsideTheMagic.net for more about Maleficent! "Maleficent" explores the untold story of Disney's most iconic villain from the classic "Sleeping Beauty" and the elements of her betrayal that ultimately turn her pure heart to stone. Driven by revenge and a fierce desire to protect the moors over which she presides, Maleficent cruelly places an irrevocable curse upon the human king's newborn infant Aurora. As the child grows, Aurora is caught in the middle of the seething conflict between the forest kingdom she has grown to love and the human kingdom that holds her legacy. Maleficent realizes that Aurora may hold the key to peace in the land and is forced to take drastic actions that will change both worlds forever.
Solo por diversión, quería solo tener algo para mí en video y solo decidí compartirlo, grabo muy mal pero espero mejorar. www.facebook.com/DomineKiraPhoto Gracias a Alex Reynaud por editarlo y hacerle milagros.


text:
Aishwarya Rakesh
Russia to Set Up Nuclear Warship Logistics Hub in Sudan
Russian President Vladimir Putin with Chairman of Sudan's Sovereign Council Abdel Fattah al-Burhan in Sochi, in October 2019.
Russia plans to establish a military logistics hub for nuclear warships and station its vessels in the Red Sea city of Port Sudan that will allow it to ferry weapons in and out of the African nation.
As per the new draft deal published by the government recently, the Navy will station up to four warships and up to 300 service members in the Sudanese port. On November 11, Russia's Meduza reported sighting four vessels resembling warships at the location.
Russia will also be able to import and export weapons, ammunition and supplies for the warships, duty-free and exempt from scrutiny. In return, Sudan will receive free assistance in search-and-rescue operations and support in anti-sabotage efforts from Russia.
The agreement states that the plan to open the hub "is defensive and not directed against other countries" and that it "meets the goals of maintaining peace and stability in the region."
In May 2019, the two countries signed a seven-year military cooperation deal that gave Russian Navy access to Sudanese ports. Sudan's Armed Forces are said to be 60% equipped with military hardware supplied by either the Soviet Union or Russia.
Germany's Bild newspaper wrote in August citing a leaked secret German Foreign Ministry document that the Russians are building military bases in six African countries - Sudan, Central African Republic, Egypt, Eritrea, Madagascar and Mozambique.
"The date of the requested port call is being discussed. It will be approved if the two countries make an agreement. This deal will pave the way for more agreements and greater cooperation… possibly a Russian base on the Red Sea," the head of Sudan's parliamentary defense committee, MG Al-Hadi Adam, had stated earlier, in December 2019.
Russia has emerged as the biggest supplier of weapons to Africa and accounts for half of the region's arms market pie. Between 2015 to 2019, Africa has imported 49% of its military equipment from Russia, which is nearly twice the volume of that purchased from its next two suppliers- the United States (14%) and China (13%).
Russia Gifts Armored Personnel Carriers to Central African Republic
October 16, 2020 @ 05:23 AM
A batch of ten BRDM-2 armored personnel carriers arrived in Central African Republic on Thursday. "The first batch of the vehicles has been delivered
Russia seeks to Establish Military Bases in 6 African Nations
August 4, 2020 @ 06:31 PM
Russia has sought permission to establish military bases in 6 African countries- Egypt, the Central African Republic, Eritrea, Madagascar, Mozambique, and Sudan. Germanys Bild newspaper reported quoting German Foreign Ministry documents on August 4, that Russia...
Rosoboronexport Signs Contract with African Nation to Supply Fast Assault Boats
April 10, 2020 @ 10:10 AM
Rosoboronexport has begun its first export of Project 02450 fast assault boats BK-10 designed and manufactured by Kalashnikov Concern to a Sub-Saharan African Nation. "A contract signed recently by Rosoboronexport was the first document for the...
Russian Arms Sales Growing in Africa
March 24, 2020 @ 01:35 PM
Russia has emerged as the biggest supplier of weapons to Africa and accounts for half of the regions arms market pie, more than twice that of China and the United States. According to Stockholm International Peace...
Russia-Sudan Sign Agreement on Creating Logistics Center in Red Sea City
Russia and Sudan have signed an agreement to establish a military logistics center for the Russian Navy in the Red Sea City of Port Sudan. According to an official document published Tuesday, the agreement was signed...
Russian Kazan Nuclear Submarine Fires Anti-ship Missile in Final Trials
The Russian Navys Kazan nuclear submarine completed state trials with the launch of Oniks anti-ship cruise missile in White Sea. "Today, the lead ship of the Yasen-M project, Kazan, has successfully fired an Oniks anti-ship cruise...

redpajama_set_name: RedPajamaCommonCrawl


If you are a faculty or staff member, and would like to request an enhancement to LionPATH, please complete the LionPATH Enhancement Request Form.
The LDMO is continuing to accept enhancement requests, however, most will be put on hold until after July 2019 in order to dedicate time to the necessary preparations for the system's upgrade.
Requests must be submitted by December 31, 2018, to be considered for approval before the March 15, 2019 system freeze.
After March 15, 2019, only emergency fixes will be made to the system.
You will be notified when your request is reopened. Please take note of the request TASK Number for future reference.
More information about the July 2019 upgrade is available at lionpathsupport.psu.edu/july-2019-upgrade.
Note: Submitting an enhancement request does not signify that your request has been accepted and will be done. The form is simply a mechanism for submitting requests. The LionPATH team will follow up to obtain more information, and to notify you as to whether and when your request can be done.


"Light." Science, Energy, Q-files Encyclopedia, 2 Oct. 2013.
Science, Energy, s.v. "Light," accessed April 20, 2019.
A close-up of a halogen light bulb, showing the filament, a thin wire wound in a tight coil, made of tungsten. When electricity passes through the coil it becomes white hot. The bulb contains a small amount of a halogen, such as iodine or bromine. The combination of the halogen gas and the tungsten filament produces a chemical reaction in which evaporated tungsten recoats the filament, prolonging its life.
Light is the form of energy that our eyes can detect, enabling us to see. It is produced by very hot things—stars like the Sun, fire and the tiny wires inside electric light bulbs. Certain animals also have light-producing organs. Light rays can travel only in straight lines, although they can be reflected. If they strike an object which does not allow light to pass through (an opaque object), a shadow is cast on the unlit side. Sunlight is made up of all the colours of the rainbow: the spectrum of light. Light from the Sun is essential to most life-forms on Earth. Plants use sunlight to make their food, a process called photosynthesis. Thus all plant-eating animals, together with other animals that eat plant-eaters, also depend on sunlight.
An illustration showing different sources of light: moonlight (reflected sunlight), glow worms in a bush and light produced by electricity: torches, car headlights and a ship's lights.
Stars are so distant from Earth that their light may take many years to reach us, even travelling at 300,000 kilometres per second.


text:
/*
    Implements a simplistic WEB server.  Every time a connection is made and
    data is received a dynamic page that shows the current TCP/IP statistics
    is generated and returned.  The connection is then closed.

    This file was adapted from a FreeRTOS lwIP slip demo supplied by a third
    party.
*/

/* ------------------------ System includes ------------------------------- */

/* ------------------------ FreeRTOS includes ----------------------------- */
#include "FreeRTOS.h"
#include "task.h"
#include "semphr.h"

/* ------------------------ lwIP includes --------------------------------- */
#include "lwip/api.h"
#include "lwip/tcpip.h"
#include "lwip/ip.h"
#include "lwip/memp.h"
#include "lwip/stats.h"
#include "netif/loopif.h"

/* ------------------------ Project includes ------------------------------ */
#include <string.h>
#include "main.h"

#include "webserver.h"
#include "wlan_intf.h"

#define CONFIG_READ_FLASH	1

#ifdef CONFIG_READ_FLASH

#ifndef CONFIG_PLATFORM_8195A

#include <flash/stm32_flash.h>
#if defined(STM32F2XX)
#include <stm32f2xx_flash.h>
#elif defined(STM32F4XX)
#include <stm32f4xx_flash.h>
#elif defined(STM32f1xx)
#include <stm32f10x_flash.h>
#endif

#else
#include "flash_api.h"
#include "device_lock.h"
#define DATA_SECTOR     AP_SETTING_SECTOR
#define BACKUP_SECTOR	(0x00008000)

#endif
#endif
/* ------------------------ Defines --------------------------------------- */
/* The size of the buffer in which the dynamic WEB page is created. */
#define webMAX_PAGE_SIZE       (3200/* 2800 */) /*FSL: buffer containing array*/
#define LOCAL_BUF_SIZE        800
#define AP_SETTING_ADDR			AP_SETTING_SECTOR
/* Standard GET response. */
#define webHTTP_OK  "HTTP/1.0 200 OK\r\nContent-type: text/html\r\n\r\n"

/* The port on which we listen. */
#define webHTTP_PORT            ( 80 )

/* Delay on close error. */
#define webSHORT_DELAY          ( 10 )

#define USE_DIV_CSS 1

#if USE_DIV_CSS

/* Format of the dynamic page that is returned on each connection. */
#define webHTML_HEAD_START \
"\
\
"
/*
<meta http-equiv=\"Content-Type\" content=\"text/html;charset=gb2312>\
<meta http-equiv=\"Cache-Control\" CONTENT=\"no-cache\">\
<meta http-equiv=\"Expires\" CONTENT=\"0\">\
*/

#define webHTML_TITLE \
"<title>Realtek SoftAP Config UI</title>"

#define webHTML_BODY_START \
"\
\
<form method=\"post\" onSubmit=\"return onSubmitForm()\" >\

\

\
Realtek SoftAP Configuration\

"

#define webHTML_CSS \
""

#define webHTML_END \
"
\
<input  type=\"submit\" value=\"Submit\">\

\

\
Copyright ©realtek.com\

\

\
 </form>\
\
\
"

#define webWaitHTML_START \
"\
\
"
#define webWaitHTML_END \
"\
\

\

SoftAP is now restarting!
\

Please wait a moment and reconnect!
\

"\
"\r\n" \
""

#define onChangeSecType \
""

#define onSubmitForm \
""

#else

/* Format of the dynamic page that is returned on each connection. */
#define webHTML_HEAD_START \
"\
\
"
/*
<meta http-equiv=\"Content-Type\" content=\"text/html;charset=gb2312>\
<meta http-equiv=\"Cache-Control\" CONTENT=\"no-cache\">\
<meta http-equiv=\"Expires\" CONTENT=\"0\">\
*/

#define webHTML_BODY_START \
"\
\
\r\n\r\n<form name=\"form\" method=\"post\" onsubmit=\"return onSubmitForm()\">\

\

\
\

Realtek SoftAP Configuration
\
	\

"

#define webHTML_END \
"
\
\
<input type=\"submit\" value=\"Submit\">
	\

\

\
\
Copyright ?realtek.com	\

\

\
\r\n</form>" \
"\r\n" \
""

#define webWaitHTML_START \
"\
\
"
#define webWaitHTML_END \
"\
\

\

SoftAP is now restarting!
\

Please wait a moment and reconnect!
\

"\
"\r\n" \
""

#define onChangeSecType \
""

#define onSubmitForm \
""

#endif

/*
alert(\"Please enter your password!\");\
return false;\
}\
if(z.value.length < 8)\
{\
alert(\"Your password is too short!(8-32)\");\
return false;\
}\
if(z.value.length>32)\
{\
alert(\"Your password is too long!(8-32)\");\
*/

#define MAX_SOFTAP_SSID_LEN      32
#define MAX_PASSWORD_LEN          32
#define MAX_CHANNEL_NUM             13

#if INCLUDE_uxTaskGetStackHighWaterMark
	static volatile unsigned portBASE_TYPE uxHighWaterMark_web = 0;
#endif

/* ------------------------ Prototypes ------------------------------------ */
static void     vProcessConnection( struct netconn *pxNetCon );

/*------------------------------------------------------------------------------*/
/*                            GLOBALS                                          */
/*------------------------------------------------------------------------------*/
rtw_wifi_setting_t wifi_setting = {RTW_MODE_NONE, {0}, 0, RTW_SECURITY_OPEN, {0}};

#ifndef WLAN0_NAME
  #define WLAN0_NAME		"wlan0"
#endif

#ifndef WLAN1_NAME
  #define WLAN1_NAME      	"wlan1"
#endif

static void LoadWifiSetting()
{
    const char *ifname = WLAN0_NAME;

    if(rltk_wlan_running(WLAN1_IDX))
    {//STA_AP_MODE
    	ifname = WLAN1_NAME;
    }

    wifi_get_setting(ifname, &wifi_setting);

    //printf("\r\nLoadWifiSetting(): wifi_setting.ssid=%s\n", wifi_setting.ssid);
    //printf("\r\nLoadWifiSetting(): wifi_setting.channel=%d\n", wifi_setting.channel);
    //printf("\r\nLoadWifiSetting(): wifi_setting.security_type=%d\n", wifi_setting.security_type);
    //printf("\r\nLoadWifiSetting(): wifi_setting.password=%s\n", wifi_setting.password);
}

#if CONFIG_READ_FLASH
#ifndef CONFIG_PLATFORM_8195A
void LoadWifiConfig()
{
    rtw_wifi_config_t local_config;
    uint32_t address;
#ifdef STM32F10X_XL
    address = 0x08080000;   //bank2 domain
#else
    uint16_t sector_nb = FLASH_Sector_11;
    address = flash_SectorAddress(sector_nb);
#endif
    printf("\r\nLoadWifiConfig(): Read from FLASH!\n");
    flash_Read(address, (char *)&local_config, sizeof(local_config));

    printf("\r\nLoadWifiConfig(): local_config.boot_mode=0x%x\n", local_config.boot_mode);
    printf("\r\nLoadWifiConfig(): local_config.ssid=%s\n", local_config.ssid);
    printf("\r\nLoadWifiConfig(): local_config.channel=%d\n", local_config.channel);
    printf("\r\nLoadWifiConfig(): local_config.security_type=%d\n", local_config.security_type);
    printf("\r\nLoadWifiConfig(): local_config.password=%s\n", local_config.password);

    if(local_config.boot_mode == 0x77665502)
    {
        wifi_setting.mode = RTW_MODE_AP;
        if(local_config.ssid_len > 32)
            local_config.ssid_len = 32;
        memcpy(wifi_setting.ssid, local_config.ssid, local_config.ssid_len);
        wifi_setting.ssid[local_config.ssid_len] = '\0';
        wifi_setting.channel = local_config.channel;
        wifi_setting.security_type = local_config.security_type;
        if(local_config.password_len > 32)
            local_config.password_len = 32;
        memcpy(wifi_setting.password, local_config.password, local_config.password_len);
        wifi_setting.password[local_config.password_len] = '\0';
    }
    else
    {
        LoadWifiSetting();
    }
}

int StoreApInfo()
{
	rtw_wifi_config_t wifi_config;
	uint32_t address;
#ifdef STM32F10X_XL
	address = 0x08080000;	//bank2 domain
#else
	uint16_t sector_nb = FLASH_Sector_11;
	address = flash_SectorAddress(sector_nb);
#endif
	// clean wifi_config first
	memset(&wifi_config, 0x00, sizeof(rtw_wifi_config_t));

	wifi_config.boot_mode = 0x77665502;
	memcpy(wifi_config.ssid, wifi_setting.ssid, strlen((char*)wifi_setting.ssid));
	wifi_config.ssid_len = strlen((char*)wifi_setting.ssid);
	wifi_config.security_type = wifi_setting.security_type;
	memcpy(wifi_config.password, wifi_setting.password, strlen((char*)wifi_setting.password));
	wifi_config.password_len= strlen((char*)wifi_setting.password);
	wifi_config.channel = wifi_setting.channel;

	printf("\n\rWritting boot mode 0x77665502 and Wi-Fi setting to flash ...");
#ifdef STM32F10X_XL
	FLASH_ErasePage(address);
#else
	flash_EraseSector(sector_nb);
#endif
	flash_Wrtie(address, (char *)&wifi_config, sizeof(rtw_wifi_config_t));

	return 0;
}

#else

void LoadWifiConfig()
{

    flash_t flash;

    rtw_wifi_config_t local_config;
    uint32_t address;

    address = DATA_SECTOR;

    //memset(&local_config,0,sizeof(rtw_wifi_config_t));
    printf("\r\nLoadWifiConfig(): Read from FLASH!\n");
   // flash_Read(address, &local_config, sizeof(local_config));

    device_mutex_lock(RT_DEV_LOCK_FLASH);
    flash_stream_read(&flash, address, sizeof(rtw_wifi_config_t),(uint8_t *)(&local_config));
	device_mutex_unlock(RT_DEV_LOCK_FLASH);

    printf("\r\nLoadWifiConfig(): local_config.boot_mode=0x%x\n", local_config.boot_mode);
    printf("\r\nLoadWifiConfig(): local_config.ssid=%s\n", local_config.ssid);
    printf("\r\nLoadWifiConfig(): local_config.channel=%d\n", local_config.channel);
    printf("\r\nLoadWifiConfig(): local_config.security_type=%d\n", local_config.security_type);
    printf("\r\nLoadWifiConfig(): local_config.password=%s\n", local_config.password);

    if(local_config.boot_mode == 0x77665502)
    {
        wifi_setting.mode = RTW_MODE_AP;
        if(local_config.ssid_len > 32)
            local_config.ssid_len = 32;
        memcpy(wifi_setting.ssid, local_config.ssid, local_config.ssid_len);
        wifi_setting.ssid[local_config.ssid_len] = '\0';
        wifi_setting.channel = local_config.channel;
        if(local_config.security_type == 1)
          wifi_setting.security_type = RTW_SECURITY_WPA2_AES_PSK;
        else
          wifi_setting.security_type = RTW_SECURITY_OPEN;
        if(local_config.password_len > 32)
            local_config.password_len = 32;
        memcpy(wifi_setting.password, local_config.password, local_config.password_len);
        wifi_setting.password[local_config.password_len] = '\0';
    }
    else
    {
        LoadWifiSetting();
    }

}

int StoreApInfo()
{

    flash_t flash;

    rtw_wifi_config_t wifi_config;
    uint32_t address;
    uint32_t data,i = 0;

    // clean wifi_config first
    memset(&wifi_config, 0x00, sizeof(rtw_wifi_config_t));

    address = DATA_SECTOR;

    wifi_config.boot_mode = 0x77665502;
    memcpy(wifi_config.ssid, wifi_setting.ssid, strlen((char*)wifi_setting.ssid));
    wifi_config.ssid_len = strlen((char*)wifi_setting.ssid);
    wifi_config.security_type = wifi_setting.security_type;
    if(wifi_setting.security_type !=0)
        wifi_config.security_type = 1;
    else
        wifi_config.security_type = 0;
    memcpy(wifi_config.password, wifi_setting.password, strlen((char*)wifi_setting.password));
    wifi_config.password_len= strlen((char*)wifi_setting.password);
    wifi_config.channel = wifi_setting.channel;
    printf("\n\rWritting boot mode 0x77665502 and Wi-Fi setting to flash ...");
    //printf("\n\r &wifi_config = 0x%x",&wifi_config);

   flash_read_word(&flash,address,&data);

    if(data == ~0x0){
	  device_mutex_lock(RT_DEV_LOCK_FLASH);
      flash_stream_write(&flash, address,sizeof(rtw_wifi_config_t), (uint8_t *)&wifi_config);
	  device_mutex_unlock(RT_DEV_LOCK_FLASH);
    }else{
    //flash_EraseSector(sector_nb);

        device_mutex_lock(RT_DEV_LOCK_FLASH);
        flash_erase_sector(&flash,BACKUP_SECTOR);
        for(i = 0; i < 0x1000; i+= 4){
            flash_read_word(&flash, DATA_SECTOR + i, &data);
            if(i < sizeof(rtw_wifi_config_t))
            {
                 memcpy(&data,(char *)(&wifi_config) + i,4);
                 //printf("\n\r Wifi_config + %d = 0x%x",i,(void *)(&wifi_config + i));
                 //printf("\n\r Data = %d",data);
            }
            flash_write_word(&flash, BACKUP_SECTOR + i,data);
        }
        flash_read_word(&flash,BACKUP_SECTOR + 68,&data);
        //printf("\n\r Base + BACKUP_SECTOR + 68 wifi channel = %d",data);
        //erase system data
        flash_erase_sector(&flash, DATA_SECTOR);
        //write data back to system data
        for(i = 0; i < 0x1000; i+= 4){
            flash_read_word(&flash, BACKUP_SECTOR + i, &data);
            flash_write_word(&flash, DATA_SECTOR + i,data);
        }
                  //erase backup sector
           flash_erase_sector(&flash, BACKUP_SECTOR);
        }
        device_mutex_unlock(RT_DEV_LOCK_FLASH);
	//flash_Wrtie(address, (char *)&wifi_config, sizeof(rtw_wifi_config_t));
	//flash_stream_write(&flash, address,sizeof(rtw_wifi_config_t), (uint8_t *)&wifi_config);
	//flash_stream_read(&flash, address, sizeof(rtw_wifi_config_t),data);
        //flash_stream_read(&flash, address, sizeof(rtw_wifi_config_t),data);
	//printf("\n\r Base + 0x000FF000 +4  wifi config  = %s",data[4]);
        //printf("\n\r Base + 0x000FF000 +71 wifi channel = %d",data[71]);

	return 0;
}

int EraseApinfo(){
	flash_t flash;
	uint32_t address;

	address = DATA_SECTOR;
	device_mutex_lock(RT_DEV_LOCK_FLASH);
	flash_erase_sector(&flash, address);
	device_mutex_unlock(RT_DEV_LOCK_FLASH);
	return 0;
}
#endif

#endif

static void RestartSoftAP()
{
	//printf("\r\nRestartAP: ssid=%s", wifi_setting.ssid);
	//printf("\r\nRestartAP: ssid_len=%d", strlen((char*)wifi_setting.ssid));
	//printf("\r\nRestartAP: security_type=%d", wifi_setting.security_type);
	//printf("\r\nRestartAP: password=%s", wifi_setting.password);
	//printf("\r\nRestartAP: password_len=%d", strlen((char*)wifi_setting.password));
	//printf("\r\nRestartAP: channel=%d\n", wifi_setting.channel);
	wifi_restart_ap(wifi_setting.ssid,
					wifi_setting.security_type,
					wifi_setting.password,
					strlen((char*)wifi_setting.ssid),
					strlen((char*)wifi_setting.password),
					wifi_setting.channel);
}

u32 web_atoi(char* s)
{
	int num=0,flag=0;
	int i;

	for(i=0;i<=strlen(s);i++)
	{
		if(s[i] >= '0' && s[i] <= '9')
			num = num * 10 + s[i] -'0';
		else if(s[0] == '-' && i==0)
			flag =1;
		else
			break;
	}

	if(flag == 1)
		num = num * -1;

	return(num);
}

static void CreateSsidTableItem(char *pbuf, u8_t *ssid, u8_t ssid_len)
{
    char local_ssid[MAX_SOFTAP_SSID_LEN+1];

    if(ssid_len > MAX_SOFTAP_SSID_LEN)
        ssid_len = MAX_SOFTAP_SSID_LEN;
    memcpy(local_ssid, ssid, ssid_len);
    local_ssid[ssid_len] = '\0';

#if USE_DIV_CSS
    sprintf(pbuf, "

SoftAP SSID:

" \
			"<input class=\"box\" type=\"text\" name=\"Ssid\" id=\"Ssid\" value=\"%s\">

",
                        local_ssid);
#else
    sprintf(pbuf, "
"
                        ""
                        "SoftAP SSID:
"
                        "	"
                        ""
                        "<input type=\"text\" name=\"Ssid\" id=\"Ssid\" value=\"%s\">
"
                        "	"
                        "
",
                        local_ssid);

#endif
    //printf("\r\nstrlen(SsidTableItem)=%d\n", strlen(pbuf));
}

static void CreateSecTypeTableItem(char *pbuf, u32_t sectype)
{
    u8_t flag[2] = {0, 0};

    if(sectype == RTW_SECURITY_OPEN)
	flag[0] = 1;
    else if(sectype == RTW_SECURITY_WPA2_AES_PSK)
        flag[1] = 1;
    else
        return;

#if USE_DIV_CSS
    sprintf(pbuf, "

Security Type:

"\
             	"<select  class=\"box\" name=\"Security Type\"  id=\"sec\" onChange=onChangeSecType()>"\
             	"<option value=\"open\" %s>OPEN</option><option value=\"wpa2-aes\" %s>WPA2-AES</option>"\
             	"</select>

",
                        flag[0]?"selected":"",
                        flag[1]?"selected":"");
#else
    sprintf(pbuf, "
"
                        ""
                        "Security Type:
"
                        "	"
                        ""
                        "<select name=\"Security Type\"  id=\"sec\" onChange=onChangeSecType()>"
                        "<option value=\"open\" %s>OPEN</option>"
                        "<option value=\"wpa2-aes\" %s>WPA2-AES</option>"
                        "</select>"
                        "	"
                        "
",
                        flag[0]?"selected":"",
                        flag[1]?"selected":"");

#endif

    //printf("\r\nstrlen(SecTypeTableItem)=%d\n", strlen(pbuf));
}

static void CreatePasswdTableItem(char *pbuf, u8_t *password, u8_t passwd_len)
{
    char local_passwd[MAX_PASSWORD_LEN+1];

    if(passwd_len > MAX_PASSWORD_LEN)
        passwd_len = MAX_PASSWORD_LEN;
    if(passwd_len > 0)
    {
        memcpy(local_passwd, password, passwd_len);
        local_passwd[passwd_len] = '\0';
    }

#if USE_DIV_CSS

     sprintf(pbuf,	"

Password:
"\
				"
"\
				"<input  class=\"box\" id=\"pwd_val\" type=\"text\" name=\"Password\" value=\"%s\" >"\
				"

",
                        passwd_len?local_passwd:"");
#else
    sprintf(pbuf, "
"
                        ""
                        "Password:
"
                        "	"
                        ""
                        "<input type=\"text\" name=\"Password\" id=\"pwd\" value=\"%s\" >
"
                        "	"
                        "
",
                        passwd_len?local_passwd:"");

#endif

    //printf("\r\nstrlen(passwordTableItem)=%d\n", strlen(pbuf));
}

static void CreateChannelTableItem(char *pbuf, u8_t channel)
{
    u8_t flag[MAX_CHANNEL_NUM+1] = {0};

    if(channel > MAX_CHANNEL_NUM){
        printf("Channel(%d) is out of range!\n", channel);
        channel = 1;
    }
    flag[channel] = 1;

#if USE_DIV_CSS

   sprintf(pbuf, "

Channel:
"
			   "
<select  class=\"box\" name=\"Channel\">"
                        "<option value=\"1\" %s>1</option>"
                        "<option value=\"2\" %s>2</option>"
                        "<option value=\"3\" %s>3</option>"
                        "<option value=\"4\" %s>4</option>"
                        "<option value=\"5\" %s>5</option>"
                        "<option value=\"6\" %s>6</option>"
                        "<option value=\"7\" %s>7</option>"
                        "<option value=\"8\" %s>8</option>"
                        "<option value=\"9\" %s>9</option>"
                        "<option value=\"10\" %s>10</option>"
                        "<option value=\"11\" %s>11</option>"
			   "</select>

",

                        flag[1]?"selected":"",
                        flag[2]?"selected":"",
                        flag[3]?"selected":"",
                        flag[4]?"selected":"",
                        flag[5]?"selected":"",
                        flag[6]?"selected":"",
                        flag[7]?"selected":"",
                        flag[8]?"selected":"",
                        flag[9]?"selected":"",
                        flag[10]?"selected":"",
                        flag[11]?"selected":"");
#else
  	 sprintf(pbuf, "
"
                        ""
                        "Channel:
"
                        "	"
                        ""
                        "<select name=\"Channel\">"
                        "<option value=\"1\" %s>1</option>"
                        "<option value=\"2\" %s>2</option>"
                        "<option value=\"3\" %s>3</option>"
                        "<option value=\"4\" %s>4</option>"
                        "<option value=\"5\" %s>5</option>"
                        "<option value=\"6\" %s>6</option>"
                        "<option value=\"7\" %s>7</option>"
                        "<option value=\"8\" %s>8</option>"
                        "<option value=\"9\" %s>9</option>"
                        "<option value=\"10\" %s>10</option>"
                        "<option value=\"11\" %s>11</option>"
                        "</select>"
                        "	"
                        "
",
                        flag[1]?"selected":"",
                        flag[2]?"selected":"",
                        flag[3]?"selected":"",
                        flag[4]?"selected":"",
                        flag[5]?"selected":"",
                        flag[6]?"selected":"",
                        flag[7]?"selected":"",
                        flag[8]?"selected":"",
                        flag[9]?"selected":"",
                        flag[10]?"selected":"",
                        flag[11]?"selected":"");

#endif

    //printf("\r\nstrlen(ChannelTableItem)=%d\n", strlen(pbuf));
}

static void GenerateIndexHtmlPage(portCHAR* cDynamicPage, portCHAR *LocalBuf)
{
        /* Generate the page index.html...
           ... First the page header. */
        strcpy( cDynamicPage, webHTML_HEAD_START );

        /* Add script */
        strcat( cDynamicPage, onChangeSecType );
        strcat( cDynamicPage, onSubmitForm);
#if USE_DIV_CSS
        /* add css */
        strcat( cDynamicPage, webHTML_CSS);

        strcat( cDynamicPage, webHTML_TITLE);
#endif
        /* Add Body start */
        strcat( cDynamicPage, webHTML_BODY_START );

        /* Add SSID */
        CreateSsidTableItem(LocalBuf, wifi_setting.ssid, strlen((char*)wifi_setting.ssid));
        strcat( cDynamicPage, LocalBuf );

        /* Add SECURITY TYPE  */
        CreateSecTypeTableItem(LocalBuf, wifi_setting.security_type);
        strcat( cDynamicPage, LocalBuf );

        /* Add PASSWORD */
        CreatePasswdTableItem(LocalBuf, wifi_setting.password, strlen((char*)wifi_setting.password));
        strcat( cDynamicPage, LocalBuf );

        /* Add CHANNEL  */
        CreateChannelTableItem(LocalBuf, wifi_setting.channel);
        strcat( cDynamicPage, LocalBuf );

        /* ... Finally the page footer. */
        strcat( cDynamicPage, webHTML_END );
        //printf("\r\nGenerateIndexHtmlPage(): %s\n", cDynamicPage);
        printf("\r\nGenerateIndexHtmlPage Len: %d\n", strlen( cDynamicPage ));
}

static void GenerateWaitHtmlPage(portCHAR* cDynamicPage)
{
        /* Generate the dynamic page...
           ... First the page header. */
        strcpy( cDynamicPage, webWaitHTML_START );

        /* ... Finally the page footer. */
        strcat( cDynamicPage, webWaitHTML_END);

        //printf("\r\nGenerateWaitHtmlPage(): %s\n",  cDynamicPage);
        //printf("\r\nGenerateWaitHtmlPage Len: %d\n", strlen( cDynamicPage ));
}

static void http_translate_url_encode(char *ptr)
{

	char *data = ptr;
	char tmp_data[3] = {0};
	char outdata[33] = {0};
	int buffer;
	char *outdata_ptr = outdata;

	while (*data != '\0') {

		if (*data == '%') {
			if ((*(data + 1) != 0) &&  (*(data + 2) != 0)) {
				tmp_data[0] = *(data + 1);
				tmp_data[1] = *(data + 2);
				sscanf(tmp_data, "%x", &buffer);
				*outdata_ptr = (char)buffer;

				/* destroy data */
				*data  = 0;
				*(data+1)  = 0;
				*(data+2)  = 0;

				data += 2;
				outdata_ptr++;
			}

		} else {
		  *outdata_ptr = *data;
		  if (*data == '+')
		    *outdata_ptr = ' ';
		  outdata_ptr++;
		}
		data++;
	}
	strcpy(ptr, outdata);

}

static u8_t ProcessPostMessage(struct netbuf  *pxRxBuffer, portCHAR *LocalBuf)
{
    struct pbuf *p;
    portCHAR *pcRxString, *ptr;
    unsigned portSHORT usLength;
    u8_t bChanged = 0;
    rtw_security_t secType;
    u8_t channel;
    u8_t len = 0;

    pcRxString = LocalBuf;
    p = pxRxBuffer->p;
    usLength = p->tot_len;
    //printf("\r\n !!!!!!!!!POST!p->tot_len =%d p->len=%d\n", p->tot_len, p->len);
    while(p)
    {
        memcpy(pcRxString, p->payload, p->len);
        pcRxString += p->len;
        p = p->next;
    }
    pcRxString = LocalBuf;
    pcRxString[usLength] = '\0';
    //printf("\r\n usLength=%d pcRxString = %s\n", usLength, pcRxString);

    ptr = (char*)strstr(pcRxString, "Ssid=");
    if(ptr)
    {
	//printf("ssid passed = %s\n", ptr);
        pcRxString = (char*)strstr(ptr, "&");
        *pcRxString++ = '\0';
        ptr += 5;
	http_translate_url_encode(ptr);
        if(strcmp((char*)wifi_setting.ssid, ptr))
        {
            bChanged = 1;
            len = strlen(ptr);
            if(len > MAX_SOFTAP_SSID_LEN){
                len = MAX_SOFTAP_SSID_LEN;
                ptr[len] = '\0';
            }
            strcpy((char*)wifi_setting.ssid, ptr);
        }
    }

    printf("\r\n get wifi_config.ssid = %s\n", wifi_setting.ssid);
    ptr = (char*)strstr(pcRxString, "Security+Type=");
    if(ptr)
    {
        pcRxString = (char*)strstr(ptr, "&");
        *pcRxString++ = '\0';
        ptr += 14;
        if(!strcmp(ptr, "open"))
           secType = RTW_SECURITY_OPEN;
        else if(!strcmp(ptr, "wpa2-aes"))
            secType = RTW_SECURITY_WPA2_AES_PSK;
        else
            secType = RTW_SECURITY_OPEN;
        if(wifi_setting.security_type != secType)
        {
            bChanged = 1;
            wifi_setting.security_type = secType;
        }
    }

    //printf("\r\n wifi_config.security_type = %d\n", wifi_setting.security_type);
    if(wifi_setting.security_type > RTW_SECURITY_OPEN)
    {
        ptr = (char*)strstr(pcRxString, "Password=");
        if(ptr)
        {
            pcRxString = (char*)strstr(ptr, "&");
            *pcRxString++ = '\0';
            ptr += 9;
            if(strcmp((char*)wifi_setting.password, ptr))
            {
                bChanged = 1;
                len = strlen(ptr);
                if(len > MAX_PASSWORD_LEN){
                    len = MAX_PASSWORD_LEN;
                    ptr[len] = '\0';
                }
                strcpy((char*)wifi_setting.password, ptr);
            }
        }
        //printf("\r\n wifi_config.password = %s\n", wifi_setting.password);
    }
    ptr = (char*)strstr(pcRxString, "Channel=");
    if(ptr)
    {
        ptr += 8;
        channel = web_atoi(ptr);
        if((channel>MAX_CHANNEL_NUM)||(channel < 1))
            channel = 1;
        if(wifi_setting.channel !=channel)
        {
            bChanged = 1;
            wifi_setting.channel = channel;
        }
    }
    //printf("\r\n wifi_config.channel = %d\n", wifi_setting.channel);

    return bChanged;
}

struct netconn *pxHTTPListener = NULL;
static void vProcessConnection( struct netconn *pxNetCon )
{
    static portCHAR cDynamicPage[webMAX_PAGE_SIZE];
    struct netbuf  *pxRxBuffer, *pxRxBuffer1 = NULL;
    portCHAR       *pcRxString;
    unsigned portSHORT usLength;
    static portCHAR LocalBuf[LOCAL_BUF_SIZE];
    u8_t bChanged = 0;
    int ret_recv = ERR_OK;
    int ret_accept = ERR_OK;
    char *ptr = NULL;

    /* Load WiFi Setting*/
    LoadWifiSetting();

    /* We expect to immediately get data. */
    port_netconn_recv( pxNetCon , pxRxBuffer, ret_recv);

    if( pxRxBuffer != NULL && ret_recv == ERR_OK)
    {
         /* Where is the data? */
        netbuf_data( pxRxBuffer, ( void * )&pcRxString, &usLength );

        //printf("\r\nusLength=%d pcRxString = \n%s\n", usLength, pcRxString);
	/* Is this a GET?  We don't handle anything else. */
        if( !strncmp( pcRxString, "GET", 3 ) )
        {
            //printf("\r\nusLength=%d pcRxString=%s \n", usLength, pcRxString);
            //pcRxString = cDynamicPage;

            /* Write out the HTTP OK header. */
            netconn_write( pxNetCon, webHTTP_OK, ( u16_t ) strlen( webHTTP_OK ), NETCONN_COPY );

            /* Generate index.html page. */
            GenerateIndexHtmlPage(cDynamicPage, LocalBuf);

            /* Write out the dynamically generated page. */
            netconn_write( pxNetCon, cDynamicPage, ( u16_t ) strlen( cDynamicPage ), NETCONN_COPY );
        }
        else if(!strncmp( pcRxString, "POST", 4 ) )
        {
            /* Write out the HTTP OK header. */
            netconn_write( pxNetCon, webHTTP_OK, ( u16_t ) strlen( webHTTP_OK ), NETCONN_COPY );

            bChanged = ProcessPostMessage(pxRxBuffer, LocalBuf);
            if(bChanged == 0){
                    port_netconn_recv( pxNetCon , pxRxBuffer1, ret_recv);
                    if(pxRxBuffer != NULL && ret_recv == ERR_OK){
                        bChanged = ProcessPostMessage(pxRxBuffer1, LocalBuf);
                        netbuf_delete( pxRxBuffer1 );
                    }
            }
            if(bChanged)
            {
                GenerateWaitHtmlPage(cDynamicPage);

                /* Write out the generated page. */
                netconn_write( pxNetCon, cDynamicPage, ( u16_t ) strlen( cDynamicPage ), NETCONN_COPY );

#if CONFIG_READ_FLASH
                StoreApInfo();
#endif
            }
            else
            {
                /* Generate index.html page. */
                GenerateIndexHtmlPage(cDynamicPage, LocalBuf);

                /* Write out the generated page. */
                netconn_write( pxNetCon, cDynamicPage, ( u16_t ) strlen( cDynamicPage ), NETCONN_COPY );
            }
        }
        netbuf_delete( pxRxBuffer );
    }
    netconn_close( pxNetCon );

    if(bChanged)
    {
        struct netconn *pxNewConnection;
        vTaskDelay(200/portTICK_RATE_MS);
        //printf("\r\n%d:before restart ap\n", xTaskGetTickCount());
        RestartSoftAP();
        //printf("\r\n%d:after restart ap\n", xTaskGetTickCount());
        pxHTTPListener->recv_timeout = 1;
        port_netconn_accept( pxHTTPListener , pxNewConnection, ret_accept);
        if( pxNewConnection != NULL && ret_accept == ERR_OK)
        {
            //printf("\r\n%d: got a conn\n", xTaskGetTickCount());
            netconn_close( pxNewConnection );
            while( netconn_delete( pxNewConnection ) != ERR_OK )
            {
                vTaskDelay( webSHORT_DELAY );
            }
        }
        //printf("\r\n%d:end\n", xTaskGetTickCount());
        pxHTTPListener->recv_timeout = 0;
    }
}

/*------------------------------------------------------------*/
xTaskHandle webs_task = NULL;
xSemaphoreHandle webs_sema = NULL;
u8_t webs_terminate = 0;
void vBasicWEBServer( void *pvParameters )
{
    struct netconn *pxNewConnection;
    //struct ip_addr  xIpAddr, xNetMast, xGateway;
    extern err_t ethernetif_init( struct netif *netif );
    int ret = ERR_OK;
    /* Parameters are not used - suppress compiler error. */
    ( void )pvParameters;

    /* Create a new tcp connection handle */
    pxHTTPListener = netconn_new( NETCONN_TCP );
    ip_set_option(pxHTTPListener->pcb.ip, SOF_REUSEADDR);
    netconn_bind( pxHTTPListener, NULL, webHTTP_PORT );
    netconn_listen( pxHTTPListener );

#if CONFIG_READ_FLASH
  /* Load wifi_config */
    LoadWifiConfig();
    RestartSoftAP();
#endif
    //printf("\r\n-0\n");

    /* Loop forever */
    for( ;; )
    {
        if(webs_terminate)
            break;

        //printf("\r\n%d:-1\n", xTaskGetTickCount());
        /* Wait for connection. */
        port_netconn_accept( pxHTTPListener , pxNewConnection, ret);
        //printf("\r\n%d:-2\n", xTaskGetTickCount());

        if( pxNewConnection != NULL && ret == ERR_OK)
        {
            /* Service connection. */
            vProcessConnection( pxNewConnection );
            while( netconn_delete( pxNewConnection ) != ERR_OK )
            {
                vTaskDelay( webSHORT_DELAY );
            }
        }
        //printf("\r\n%d:-3\n", xTaskGetTickCount());
    }
    //printf("\r\n-4\n");
    if(pxHTTPListener)
    {
        netconn_close(pxHTTPListener);
        netconn_delete(pxHTTPListener);
        pxHTTPListener = NULL;
    }

    //printf("\r\nExit Web Server Thread!\n");
    xSemaphoreGive(webs_sema);
}

#define STACKSIZE				512
void start_web_server()
{
    	printf("\r\nWEB:Enter start web server!\n");
	webs_terminate = 0;
	if(webs_task == NULL)
	{
		if(xTaskCreate(vBasicWEBServer, (const char *)"web_server", STACKSIZE, NULL, tskIDLE_PRIORITY + 1, &webs_task) != pdPASS)
			printf("\n\rWEB: Create webserver task failed!\n");
	}
	if(webs_sema == NULL)
	{
		webs_sema = xSemaphoreCreateCounting(0xffffffff, 0);	//Set max count 0xffffffff
	}
    	//printf("\r\nWEB:Exit start web server!\n");
}

void stop_web_server()
{
    	//printf("\r\nWEB:Enter stop web server!\n");
	webs_terminate = 1;
   	if(pxHTTPListener)
		netconn_abort(pxHTTPListener);
	if(webs_sema)
	{
		if(xSemaphoreTake(webs_sema, 15 * configTICK_RATE_HZ) != pdTRUE)
		{
			if(pxHTTPListener)
			{
				netconn_close(pxHTTPListener);
  				netconn_delete(pxHTTPListener);
				pxHTTPListener = NULL;
			}
			printf("\r\nWEB: Take webs sema(%p) failed!!!!!!!!!!!\n", webs_sema);
		}
		vSemaphoreDelete(webs_sema);
		webs_sema = NULL;
	}
	if(webs_task)
	{
		vTaskDelete(webs_task);
		webs_task = NULL;
	}
    	printf("\r\nWEB:Exit stop web server!\n");
}

redpajama_set_name: RedPajamaGithub